package com.lwgk.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import java.util.List;

/**
 * created by 赵航
 * 联系微信 微信号：zhao--hang--
 * on 2019/7/17
 * --------------------------------------------------------------------------
 * 描述：
 * 注意事项：
 */
public class HomePagerAdapter extends FragmentPagerAdapter {
    private List<Fragment> mListFragment;
    public HomePagerAdapter(FragmentManager fm, List<Fragment> fragments) {
        super(fm);
        this.mListFragment = fragments;
    }

    @Override
    public Fragment getItem(int position) {
        return mListFragment.get(position);
    }

    @Override
    public int getCount() {
        return mListFragment.size();
    }
}
